﻿<!--{inc(header.view.html)}-->

<div class="header">
  <div class="nav">
    <ul id="nav_list">
      <li><a href="#" class="nav_icon"  target="mainframe">用户列表</a></li>
      <li><a href="index.php?app=user&act=add" target="mainframe">添加用户</a></li>
    </ul>
  </div>
</div>
<div id="content">
  <h1>新增用户</h1>
  <div>
    <div class="tips_show"><img  src="{$web_view_dir}style/images/light.gif" align="absmiddle" /> <b>提示: </b> <span ></span> </div>
    <style type="text/css">
.search_box {
padding:10px;
vertical-align:middle;
}
.search_box .l {
float:left;
vertical-align:middle;
}
.search_box .r {
float:right;
}
</style>
    <form  method="post" action="?app=user&act=index" >
      <div class="search_box">
        <div class="l"><img  src="{$web_view_dir}style/images/it_nav.gif" align="middle">用户组查看:
          <select  onchange="ato_url('index.php?app=user&act=index',this);" >
            <option  class="txtgreen" value="0" selected="selected">全部用户</option>
            
            <!--{foreach($roledata as $_key => $_value )}-->
            
            <option value="{$_value.value}" <!--{if ($_value.value == $v)}-->selected<!--{/if}-->>{$_value.name}</option>
            
            <!--{/foreach}-->
            
          </select>
          &nbsp;
          排序方式:
          <select  onchange="ato_url('index.php?app=user&act=index',this);" >
            <option class="txtgreen" value="0">请选择...</option>
            <option value="timeasc" <!--{if ($v == 'timeasc')}-->selected<!--{/if}-->>时间升序↑</option>
            <option value="timedesc" <!--{if ($v == 'timedesc')}-->selected<!--{/if}-->>时间降序↓</option>
            <option value="islocked" <!--{if ($v == 'islocked')}-->selected<!--{/if}-->>锁定的用户</option>
          </select>
        </div>
        <div class="r">
          <input type="text" title="多个关键字用空格隔开" value="{$word}" name="word">
          <input type="submit" value="搜索用户" class="buton">
        </div>
      </div>
    </form>
    <div class="clear"></div>
    <table width="100%" cellspacing="0" cellpadding="4" border="0" align="center" class="table_style">
      <tbody>
        <tr>
          <td width="30%" class="bold">用户名称</td>
          <td align="center" class="bold">E-Mail</td>
          <td width="80" align="center" class="bold">用户组</td>
          <td width="150" align="center" class="bold">注册时间</td>
          <td align="center" class="bold">操作</td>
        </tr>
      <form method="post" name="user_form" action="" onsubmit="dosubmit(this)">
        
        <!--{foreach($lw_data as $_key => $_value )}-->
        
        <tr  onMouseOut="this.className=''" onMouseOver="this.className='bgcolor'">
          <td><input type="checkbox"  value="{$_value.user_id}" id="userids" name="userids[]">
            <a href="?app=user&act=edit&id={$_value.user_id}">{$_value.user_name}</a></span></td>
          <td align="center">{$_value.user_email}</td>
          <td align="center">{$rolename[$_value.role_id]}</td>
          <td align="center" class="txtgray">{$_value.reg_time|dateymdgis}</td>
          <td align="center"><a href="?app=user&act=locked&id={$_value.user_id}&s={$_value.locked}"><!--{if ($_value.locked)}-->启用<!--{else}-->锁定<!--{/if}--></a>&nbsp; <a onClick="return confirm('确认删除？该用户的文件(夹)、提取码等将会全部被删除，请慎用！');" href="?app=user&act=del&id={$_value.user_id}">删除</a></td>
        </tr>
        
        <!--{/foreach}--> 
        
        <!--<tr>
	<td class="td_line" colspan="6"><a onClick="reverse_ids();" href="javascript:void(0);">全选/反选</a>&nbsp;&nbsp;<a onClick="cancel_ids();" href="javascript:void(0);">取消选择</a>&nbsp;&nbsp;
	移动到: 
	<select name="dest_gid">
	<option class="txtgreen" value="0" selected="selected">请选择...</option>
  <!--{foreach($roledata as $_key => $_value )}-->
        
        <option value="{$_value.value}" >{$_value.name}</option>
        
        <!--{/foreach}-->
        
          </select>
        &nbsp;&nbsp;
        <input type="submit"  value=" 提 交 "  class="buton">
          </td>
        
          </tr>
        -->
      </form>
      <style type="text/css">

.p_bar {
margin-top:5px;
}
.p_info {
border:1px solid #CCCCCC;
margin:0 3px;
padding:3px 5px;
text-align:center;
}
.p_curpage {
border:1px solid #CCCCCC;
color:#FF0000;
font-weight:bold;
margin:0 2px;
padding:3px 5px;
text-align:center;
}

.p_num  {
border:1px solid #CCCCCC;
margin:0 3px;
padding:3px 5px;
text-align:center;
}
.p_redirect {
border:1px solid #CCCCCC;
margin:0 3px;
padding:3px 5px;
text-align:center;
}

a {
color:#003366;
text-decoration:none;
}


</style>
      <tr>
        <td colspan="5"><div class="p_bar"> <span class="p_info">Total:&nbsp;<b>{$lw_page.total}</b>&nbsp;&nbsp;共{$lw_page.curr.num}/{$lw_page.totalpage}页</span> <a class="p_num" href="{$lw_page.head}">首页</a> <a class="p_num" href="{$lw_page.up}">&lt;&lt;</a> <a class="p_num" href="{$lw_page.up}">上一页</a> <span class="p_curpage">{$lw_page.curr.num}</span> <a  class="p_num" href="{$lw_page.down}">下一页</a> <a  class="p_num" href="{$lw_page.down}">&gt;&gt;</a> <a  class="p_num" href="{$lw_page.foot}">末页</a> </div></td>
      </tr>
        </tbody>
    </table>
    <script language="javascript">
function reverse_ids(){
	for (var i=0;i<document.user_form.userids.length;i++) {
		var ids = document.user_form.userids[i];
		ids.checked = !ids.checked;
	}
}
function cancel_ids(){
	for (var i=0;i<document.user_form.userids.length;i++) {
		var ids = document.user_form.userids[i];
		ids.checked = false;
	}
}
function checkbox(){
	n = document.getElementsByName("userids[]");
	var j =0;
	for(i = 0; i < n.length; i++){
		if(n[i].checked){
			j++;
		}
	}
	if(j ==0){
		alert("请选择要移动的用户");
		return false;
	}else{
		return true;
	}
}

function dosubmit(o){
	if(checkbox() != true){
		return false;
	}
	if(o.dest_gid.value ==0){
		alert("请选择目标用户组");
		o.dest_gid.focus();
		return false;
	}
}
</script> 
  </div>
</div>

<!--{inc(footer.view.html)}-->